package com.antdesignbackend.backend.service.impl;

import com.antdesignbackend.backend.entity.Artist;
import com.antdesignbackend.backend.entity.entityVo.ArtistVo;
import com.antdesignbackend.backend.mapper.ArtistMapper;
import com.antdesignbackend.backend.service.ArtistService;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class ArtistServiceImpl extends ServiceImpl<ArtistMapper, Artist> implements ArtistService {
    @Autowired
    private ArtistMapper artistMapper;

    @Override
    public List<ArtistVo> search(QueryWrapper<ArtistVo> queryWrapper, Page<ArtistVo> page) {
        return artistMapper.search(queryWrapper, page);
    }
    @Override
    public Integer count(QueryWrapper<ArtistVo> queryWrapper) {
        return artistMapper.count(queryWrapper);
    }
}
